home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic Source Code / Visual Basic Source Code.iso / vbsource / 23pick / 23pickup.frm next >
Text File  |  1995-12-05  |  16KB  |  668 lines

  1. VERSION 2.00
  2. Begin Form Pickup 
  3.    BackColor       =   &H00FFFFFF&
  4.    Caption         =   "23 Pickup"
  5.    ClientHeight    =   2310
  6.    ClientLeft      =   1170
  7.    ClientTop       =   1905
  8.    ClientWidth     =   7755
  9.    Height          =   3000
  10.    Icon            =   23PICKUP.FRX:0000
  11.    Left            =   1110
  12.    LinkMode        =   1  'Source
  13.    LinkTopic       =   "Form1"
  14.    MaxButton       =   0   'False
  15.    ScaleHeight     =   2310
  16.    ScaleWidth      =   7755
  17.    Top             =   1275
  18.    Width           =   7875
  19.    Begin Timer Timer1 
  20.       Enabled         =   0   'False
  21.       Interval        =   1000
  22.       Left            =   4080
  23.       Top             =   1680
  24.    End
  25.    Begin CommandButton Command1 
  26.       Caption         =   "-&3"
  27.       FontBold        =   -1  'True
  28.       FontItalic      =   0   'False
  29.       FontName        =   "MS Sans Serif"
  30.       FontSize        =   24
  31.       FontStrikethru  =   0   'False
  32.       FontUnderline   =   0   'False
  33.       Height          =   615
  34.       Index           =   3
  35.       Left            =   5880
  36.       TabIndex        =   7
  37.       Top             =   1560
  38.       Width           =   975
  39.    End
  40.    Begin CommandButton Command1 
  41.       Caption         =   "-&2"
  42.       FontBold        =   -1  'True
  43.       FontItalic      =   0   'False
  44.       FontName        =   "MS Sans Serif"
  45.       FontSize        =   24
  46.       FontStrikethru  =   0   'False
  47.       FontUnderline   =   0   'False
  48.       Height          =   615
  49.       Index           =   2
  50.       Left            =   5880
  51.       TabIndex        =   6
  52.       Top             =   840
  53.       Width           =   975
  54.    End
  55.    Begin CommandButton Command1 
  56.       Caption         =   "-&1"
  57.       FontBold        =   -1  'True
  58.       FontItalic      =   0   'False
  59.       FontName        =   "MS Sans Serif"
  60.       FontSize        =   24
  61.       FontStrikethru  =   0   'False
  62.       FontUnderline   =   0   'False
  63.       Height          =   615
  64.       Index           =   1
  65.       Left            =   5880
  66.       TabIndex        =   0
  67.       Top             =   120
  68.       Width           =   975
  69.    End
  70.    Begin Label Label5 
  71.       BackColor       =   &H00FFFFFF&
  72.       Caption         =   "stick(s)"
  73.       FontBold        =   -1  'True
  74.       FontItalic      =   0   'False
  75.       FontName        =   "Times New Roman"
  76.       FontSize        =   18
  77.       FontStrikethru  =   0   'False
  78.       FontUnderline   =   0   'False
  79.       Height          =   495
  80.       Left            =   2160
  81.       TabIndex        =   5
  82.       Top             =   1560
  83.       Width           =   1095
  84.    End
  85.    Begin Label Label4 
  86.       BackColor       =   &H00FFFFFF&
  87.       FontBold        =   -1  'True
  88.       FontItalic      =   0   'False
  89.       FontName        =   "Times New Roman"
  90.       FontSize        =   18
  91.       FontStrikethru  =   0   'False
  92.       FontUnderline   =   0   'False
  93.       Height          =   495
  94.       Left            =   1680
  95.       TabIndex        =   4
  96.       Top             =   1560
  97.       Width           =   375
  98.    End
  99.    Begin Label Label3 
  100.       BackColor       =   &H00FFFFFF&
  101.       Caption         =   "I take"
  102.       FontBold        =   -1  'True
  103.       FontItalic      =   0   'False
  104.       FontName        =   "Times New Roman"
  105.       FontSize        =   18
  106.       FontStrikethru  =   0   'False
  107.       FontUnderline   =   0   'False
  108.       Height          =   495
  109.       Left            =   720
  110.       TabIndex        =   3
  111.       Top             =   1560
  112.       Width           =   975
  113.    End
  114.    Begin Label Label2 
  115.       Alignment       =   2  'Center
  116.       BackColor       =   &H00FFFFFF&
  117.       Caption         =   "Left"
  118.       FontBold        =   -1  'True
  119.       FontItalic      =   0   'False
  120.       FontName        =   "Arial"
  121.       FontSize        =   48
  122.       FontStrikethru  =   0   'False
  123.       FontUnderline   =   0   'False
  124.       Height          =   1095
  125.       Left            =   2040
  126.       TabIndex        =   2
  127.       Top             =   120
  128.       Width           =   2295
  129.    End
  130.    Begin Label Label1 
  131.       Alignment       =   2  'Center
  132.       BackColor       =   &H00FFFFFF&
  133.       FontBold        =   -1  'True
  134.       FontItalic      =   0   'False
  135.       FontName        =   "Arial"
  136.       FontSize        =   48
  137.       FontStrikethru  =   0   'False
  138.       FontUnderline   =   0   'False
  139.       Height          =   1095
  140.       Left            =   360
  141.       TabIndex        =   1
  142.       Top             =   120
  143.       Width           =   1455
  144.    End
  145.    Begin Menu file 
  146.       Caption         =   "&Game"
  147.       Begin Menu new 
  148.          Caption         =   "&New"
  149.          Shortcut        =   {F2}
  150.       End
  151.       Begin Menu ex 
  152.          Caption         =   "E&xit"
  153.          Shortcut        =   ^X
  154.       End
  155.       Begin Menu thing 
  156.          Caption         =   "-"
  157.       End
  158.       Begin Menu abt 
  159.          Caption         =   "&About 23 Pickup..."
  160.       End
  161.    End
  162.    Begin Menu options 
  163.       Caption         =   "&Options"
  164.       Begin Menu level 
  165.          Caption         =   "&Level of Difficulty"
  166.          Begin Menu easy 
  167.             Caption         =   "&Easy"
  168.          End
  169.          Begin Menu medium 
  170.             Caption         =   "&Medium"
  171.             Checked         =   -1  'True
  172.          End
  173.          Begin Menu hard 
  174.             Caption         =   "&Hard"
  175.          End
  176.       End
  177.       Begin Menu startplay 
  178.          Caption         =   "&Starting Player"
  179.          Begin Menu youstart 
  180.             Caption         =   "&You Start"
  181.             Checked         =   -1  'True
  182.          End
  183.          Begin Menu compstart 
  184.             Caption         =   "&Computer Starts"
  185.          End
  186.       End
  187.       Begin Menu back 
  188.          Caption         =   "&Background Color"
  189.          Begin Menu green 
  190.             Caption         =   "&Green"
  191.          End
  192.          Begin Menu blue 
  193.             Caption         =   "&Blue"
  194.          End
  195.          Begin Menu purple 
  196.             Caption         =   "&Purple"
  197.          End
  198.          Begin Menu red 
  199.             Caption         =   "&Red"
  200.          End
  201.          Begin Menu yellow 
  202.             Caption         =   "&Yellow"
  203.          End
  204.          Begin Menu bluegray 
  205.             Caption         =   "B&lue-Gray"
  206.          End
  207.          Begin Menu gray 
  208.             Caption         =   "Gr&ay"
  209.          End
  210.          Begin Menu white 
  211.             Caption         =   "&White"
  212.             Checked         =   -1  'True
  213.          End
  214.       End
  215.    End
  216.    Begin Menu help 
  217.       Caption         =   "&Help"
  218.    End
  219. End
  220.  
  221.  
  222.  
  223.  
  224.  
  225.  
  226. Sub abt_Click ()
  227. Load about
  228. about.Show
  229. End Sub
  230.  
  231. Sub blue_Click ()
  232. green.checked = 0
  233. white.checked = 0
  234. red.checked = 0
  235. yellow.checked = 0
  236. blue.checked = -1
  237. purple.checked = 0
  238. bluegray.checked = 0
  239. gray.checked = 0
  240.  
  241. h = &HFFFF00
  242. pickup.backColor = h
  243. label1.backColor = h
  244. label2.backColor = h
  245. label3.backColor = h
  246. label4.backColor = h
  247. label5.backColor = h
  248.  
  249. End Sub
  250.  
  251. Sub bluegray_Click ()
  252. green.checked = 0
  253. white.checked = 0
  254. red.checked = 0
  255. yellow.checked = 0
  256. blue.checked = 0
  257. purple.checked = 0
  258. bluegray.checked = -1
  259. gray.checked = 0
  260.  
  261. h = &H808000
  262. pickup.backColor = h
  263. label1.backColor = h
  264. label2.backColor = h
  265. label3.backColor = h
  266. label4.backColor = h
  267. label5.backColor = h
  268.  
  269. End Sub
  270.  
  271. Sub Command1_Click (Index As Integer)
  272. label4.caption = ""
  273. x = Val(label1.caption)
  274. If x < Index Then Beep: Exit Sub
  275. label1.caption = Str$(x - Index): x = Val(label1.caption)
  276. If Val(label1.caption) = 0 Then
  277.     MsgBox "You lost.", 16, "Sorry, Dude": Exit Sub
  278. End If
  279. timer1.enabled = -1
  280. End Sub
  281.  
  282. Sub Command2_Click ()
  283. x = Val(label1.caption)
  284. If x < 2 Then Beep: Exit Sub
  285. label1.caption = Str$(x - 2): x = Val(label1.caption)
  286. If Val(label1.caption) = 1 Then
  287.     label4.caption = Str$(1)
  288.     label1.caption = Str$(0)
  289.     MsgBox "You Won!", 48, "Congratulations"
  290. ElseIf Val(label1.caption) = 0 Then
  291.     MsgBox "You lost.", 16, "Sorry, Dude"
  292. End If
  293.  
  294. If i = 3 Then
  295.     For e = 1 To 21 Step 4
  296.         If x - e > 0 And x - e < 4 Then
  297.             label4.caption = Str$(x - e)
  298.